package com.ncloud.system.service;

import com.alibaba.fastjson.JSONObject;
import com.ncloud.system.entity.Menu;

import java.util.List;

/**
 * Created by shiqiang on 2017/7/28.
 */
public interface MenuService {
    int insertMenu(Menu menu);
    int updateMenu(Menu menu);
    Menu getOneMenu(Long menuId);
    int getSameMenuName(Long parentId,String menuName);
    int getSameMenuOrder(Long parentId,Integer sort);
    int updateMenuState(String useTag,Long menuId);
    List<Menu> getMenusByRole(Long userId);
    List<Menu> getMenusByUser(Long userId);
    void updateMenuSort(JSONObject json);
    int updateMenuSort(Long parentId,Integer newSort);
    int deleteMenu(Long menuId);
    List<Menu> getMenusByLevel(Long parentId);
    List<Menu> getMenusAll();
}
